<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<meta http-equiv="X-UA-Compatible" content="IE=9"/>
<title>Mali OpenCL SDK v1.1.0: /home/jenkins/workspace/opencl_sdk_daily/Architecture/x86/OS/linux/common/common.cpp File Reference</title>
<link href="tabs.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<link href="navtree.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="resize.js"></script>
<script type="text/javascript" src="navtree.js"></script>
<script type="text/javascript">
  $(document).ready(initResizable);
</script>
<link href="search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
  $(document).ready(function() { searchBox.OnSelectItem(0); });
</script>
<link href="doxygen.css" rel="stylesheet" type="text/css" />
</head>
<body>
<div id="top"><!-- do not remove this div, it is closed by doxygen! -->
<div id="titlearea">
<table cellspacing="0" cellpadding="0">
 <tbody>
 <tr style="height: 56px;">
  <td id="projectlogo"><img alt="Logo" src="logo.png"/></td>
  <td style="padding-left: 0.5em;">
   <div id="projectname">Mali OpenCL SDK v1.1.0
   </div>
  </td>
 </tr>
 </tbody>
</table>
</div>
<!-- end header part -->
<!-- Generated by Doxygen 1.8.2 -->
<script type="text/javascript">
var searchBox = new SearchBox("searchBox", "search",false,'Search');
</script>
  <div id="navrow1" class="tabs">
    <ul class="tablist">
      <li><a href="index.html"><span>Home</span></a></li>
      <li><a href="pages.html"><span>Help&#160;and&#160;Tutorials</span></a></li>
      <li class="current"><a href="files.html"><span>Files</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <span class="left">
          <img id="MSearchSelect" src="search/mag_sel.png"
               onmouseover="return searchBox.OnSearchSelectShow()"
               onmouseout="return searchBox.OnSearchSelectHide()"
               alt=""/>
          <input type="text" id="MSearchField" value="Search" accesskey="S"
               onfocus="searchBox.OnSearchFieldFocus(true)" 
               onblur="searchBox.OnSearchFieldFocus(false)" 
               onkeyup="searchBox.OnSearchFieldChange(event)"/>
          </span><span class="right">
            <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.png" alt=""/></a>
          </span>
        </div>
      </li>
    </ul>
  </div>
  <div id="navrow2" class="tabs2">
    <ul class="tablist">
      <li><a href="files.html"><span>File&#160;List</span></a></li>
      <li><a href="globals.html"><span>File&#160;Members</span></a></li>
    </ul>
  </div>
</div><!-- top -->
<div id="side-nav" class="ui-resizable side-nav-resizable">
  <div id="nav-tree">
    <div id="nav-tree-contents">
      <div id="nav-sync" class="sync"></div>
    </div>
  </div>
  <div id="splitbar" style="-moz-user-select:none;" 
       class="ui-resizable-handle">
  </div>
</div>
<script type="text/javascript">
$(document).ready(function(){initNavTree('common_8cpp.html','');});
</script>
<div id="doc-content">
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&#160;</span>All</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&#160;</span>Classes</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&#160;</span>Files</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&#160;</span>Functions</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&#160;</span>Variables</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&#160;</span>Macros</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&#160;</span>Pages</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="javascript:void(0)" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<div class="header">
  <div class="summary">
<a href="#func-members">Functions</a>  </div>
  <div class="headertitle">
<div class="title">common.cpp File Reference</div>  </div>
</div><!--header-->
<div class="contents">
<div class="textblock"><code>#include &quot;<a class="el" href="common_8h_source.html">common.h</a>&quot;</code><br/>
<code>#include &lt;iostream&gt;</code><br/>
<code>#include &lt;sstream&gt;</code><br/>
<code>#include &lt;fstream&gt;</code><br/>
</div>
<p><a href="common_8cpp_source.html">Go to the source code of this file.</a></p>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a name="func-members"></a>
Functions</h2></td></tr>
<tr class="memitem:a33ff0013574626bb47147495e02b5d08"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="common_8cpp.html#a33ff0013574626bb47147495e02b5d08">printProfilingInfo</a> (cl_event event)</td></tr>
<tr class="memdesc:a33ff0013574626bb47147495e02b5d08"><td class="mdescLeft">&#160;</td><td class="mdescRight">Print the profiling information associated with an OpenCL event.  <a href="#a33ff0013574626bb47147495e02b5d08"></a><br/></td></tr>
<tr class="separator:a33ff0013574626bb47147495e02b5d08"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a736045ae74d9ed8d35cacce59b92772a"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="common_8cpp.html#a736045ae74d9ed8d35cacce59b92772a">printSupported2DImageFormats</a> (cl_context context)</td></tr>
<tr class="memdesc:a736045ae74d9ed8d35cacce59b92772a"><td class="mdescLeft">&#160;</td><td class="mdescRight">Print a list of the 2D OpenCL image formats supported.  <a href="#a736045ae74d9ed8d35cacce59b92772a"></a><br/></td></tr>
<tr class="separator:a736045ae74d9ed8d35cacce59b92772a"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afbc9c225ddee8ca4913817d1d9f55307"><td class="memItemLeft" align="right" valign="top">string&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="common_8cpp.html#afbc9c225ddee8ca4913817d1d9f55307">imageChannelOrderToString</a> (cl_channel_order channelOrder)</td></tr>
<tr class="memdesc:afbc9c225ddee8ca4913817d1d9f55307"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert cl_channel_order values into their string form.  <a href="#afbc9c225ddee8ca4913817d1d9f55307"></a><br/></td></tr>
<tr class="separator:afbc9c225ddee8ca4913817d1d9f55307"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af351b63fc0df43f3702d01de76d344ae"><td class="memItemLeft" align="right" valign="top">string&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="common_8cpp.html#af351b63fc0df43f3702d01de76d344ae">imageChannelDataTypeToString</a> (cl_channel_type channelDataType)</td></tr>
<tr class="memdesc:af351b63fc0df43f3702d01de76d344ae"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert cl_channel_type values into their string form.  <a href="#af351b63fc0df43f3702d01de76d344ae"></a><br/></td></tr>
<tr class="separator:af351b63fc0df43f3702d01de76d344ae"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:acd459e74d0cef3c4616c7ce1a5a47f4d"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="common_8cpp.html#acd459e74d0cef3c4616c7ce1a5a47f4d">cleanUpOpenCL</a> (cl_context context, cl_command_queue commandQueue, cl_program program, cl_kernel kernel, cl_mem *memoryObjects, int numberOfMemoryObjects)</td></tr>
<tr class="memdesc:acd459e74d0cef3c4616c7ce1a5a47f4d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Release any OpenCL objects that have been created.  <a href="#acd459e74d0cef3c4616c7ce1a5a47f4d"></a><br/></td></tr>
<tr class="separator:acd459e74d0cef3c4616c7ce1a5a47f4d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6fc67d121370b02ac8bff71ec00a7665"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="common_8cpp.html#a6fc67d121370b02ac8bff71ec00a7665">createContext</a> (cl_context *context)</td></tr>
<tr class="memdesc:a6fc67d121370b02ac8bff71ec00a7665"><td class="mdescLeft">&#160;</td><td class="mdescRight">Create an OpenCL context on a GPU on the first available platform.  <a href="#a6fc67d121370b02ac8bff71ec00a7665"></a><br/></td></tr>
<tr class="separator:a6fc67d121370b02ac8bff71ec00a7665"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a30ee399cc6a4b82d46c581f037b447fa"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="common_8cpp.html#a30ee399cc6a4b82d46c581f037b447fa">createCommandQueue</a> (cl_context context, cl_command_queue *commandQueue, cl_device_id *device)</td></tr>
<tr class="memdesc:a30ee399cc6a4b82d46c581f037b447fa"><td class="mdescLeft">&#160;</td><td class="mdescRight">Create an OpenCL command queue for a given context.  <a href="#a30ee399cc6a4b82d46c581f037b447fa"></a><br/></td></tr>
<tr class="separator:a30ee399cc6a4b82d46c581f037b447fa"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4feec45e4b990aad8e40cc3faa32a9c8"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="common_8cpp.html#a4feec45e4b990aad8e40cc3faa32a9c8">createProgram</a> (cl_context context, cl_device_id device, string filename, cl_program *program)</td></tr>
<tr class="separator:a4feec45e4b990aad8e40cc3faa32a9c8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a73727ed6f5d821d8c97756404e145644"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="common_8cpp.html#a73727ed6f5d821d8c97756404e145644">checkSuccess</a> (cl_int errorNumber)</td></tr>
<tr class="memdesc:a73727ed6f5d821d8c97756404e145644"><td class="mdescLeft">&#160;</td><td class="mdescRight">Check an OpenCL error number for errors.  <a href="#a73727ed6f5d821d8c97756404e145644"></a><br/></td></tr>
<tr class="separator:a73727ed6f5d821d8c97756404e145644"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a119c92d8d25b68950de4d0e6f337df18"><td class="memItemLeft" align="right" valign="top">string&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="common_8cpp.html#a119c92d8d25b68950de4d0e6f337df18">errorNumberToString</a> (cl_int errorNumber)</td></tr>
<tr class="memdesc:a119c92d8d25b68950de4d0e6f337df18"><td class="mdescLeft">&#160;</td><td class="mdescRight">Convert OpenCL error numbers to their string form.  <a href="#a119c92d8d25b68950de4d0e6f337df18"></a><br/></td></tr>
<tr class="separator:a119c92d8d25b68950de4d0e6f337df18"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad800ae2b2358904a9051a31f76e711c3"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="common_8cpp.html#ad800ae2b2358904a9051a31f76e711c3">isExtensionSupported</a> (cl_device_id device, string extension)</td></tr>
<tr class="separator:ad800ae2b2358904a9051a31f76e711c3"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<h2 class="groupheader">Function Documentation</h2>
<a class="anchor" id="a73727ed6f5d821d8c97756404e145644"></a>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
  <tr>
  <td class="mlabels-left">
      <table class="memname">
        <tr>
          <td class="memname">bool checkSuccess </td>
          <td>(</td>
          <td class="paramtype">cl_int&#160;</td>
          <td class="paramname"><em>errorNumber</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
  </td>
  <td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inline</span></span>  </td>
  </tr>
</table>
</div><div class="memdoc">

<p>Check an OpenCL error number for errors. </p>
<p>If errorNumber is not CL_SUCESS, the function will print the string form of the error number. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">errorNumber</td><td>The error number returned from an OpenCL command. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>False if errorNumber != CL_SUCCESS, true otherwise. </dd></dl>

<p>Definition at line <a class="el" href="common_8cpp_source.html#l00358">358</a> of file <a class="el" href="common_8cpp_source.html">common.cpp</a>.</p>

</div>
</div>
<a class="anchor" id="acd459e74d0cef3c4616c7ce1a5a47f4d"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool cleanUpOpenCL </td>
          <td>(</td>
          <td class="paramtype">cl_context&#160;</td>
          <td class="paramname"><em>context</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">cl_command_queue&#160;</td>
          <td class="paramname"><em>commandQueue</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">cl_program&#160;</td>
          <td class="paramname"><em>program</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">cl_kernel&#160;</td>
          <td class="paramname"><em>kernel</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">cl_mem *&#160;</td>
          <td class="paramname"><em>memoryObjects</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">int&#160;</td>
          <td class="paramname"><em>numberOfMemoryObjects</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Release any OpenCL objects that have been created. </p>
<p>If any of the OpenCL objects passed in are not NULL, they will be freed using the appropriate OpenCL function. </p>
<dl class="section return"><dt>Returns</dt><dd>False if an error occurred, otherwise true. </dd></dl>

<p>Definition at line <a class="el" href="common_8cpp_source.html#l00170">170</a> of file <a class="el" href="common_8cpp_source.html">common.cpp</a>.</p>

</div>
</div>
<a class="anchor" id="a30ee399cc6a4b82d46c581f037b447fa"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool createCommandQueue </td>
          <td>(</td>
          <td class="paramtype">cl_context&#160;</td>
          <td class="paramname"><em>context</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">cl_command_queue *&#160;</td>
          <td class="paramname"><em>commandQueue</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">cl_device_id *&#160;</td>
          <td class="paramname"><em>device</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Create an OpenCL command queue for a given context. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">context</td><td>The OpenCL context to use. </td></tr>
    <tr><td class="paramdir">[out]</td><td class="paramname">commandQueue</td><td>The created OpenCL command queue. </td></tr>
    <tr><td class="paramdir">[out]</td><td class="paramname">device</td><td>The device in which the command queue is created. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>False if an error occurred, otherwise true. </dd></dl>

<p>Definition at line <a class="el" href="common_8cpp_source.html#l00255">255</a> of file <a class="el" href="common_8cpp_source.html">common.cpp</a>.</p>

</div>
</div>
<a class="anchor" id="a6fc67d121370b02ac8bff71ec00a7665"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool createContext </td>
          <td>(</td>
          <td class="paramtype">cl_context *&#160;</td>
          <td class="paramname"><em>context</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Create an OpenCL context on a GPU on the first available platform. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[out]</td><td class="paramname">context</td><td>Pointer to the created OpenCL context. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>False if an error occurred, otherwise true. </dd></dl>

<p>Definition at line <a class="el" href="common_8cpp_source.html#l00224">224</a> of file <a class="el" href="common_8cpp_source.html">common.cpp</a>.</p>

</div>
</div>
<a class="anchor" id="a4feec45e4b990aad8e40cc3faa32a9c8"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool createProgram </td>
          <td>(</td>
          <td class="paramtype">cl_context&#160;</td>
          <td class="paramname"><em>context</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">cl_device_id&#160;</td>
          <td class="paramname"><em>device</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">string&#160;</td>
          <td class="paramname"><em>filename</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">cl_program *&#160;</td>
          <td class="paramname"><em>program</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="common_8cpp_source.html#l00298">298</a> of file <a class="el" href="common_8cpp_source.html">common.cpp</a>.</p>

</div>
</div>
<a class="anchor" id="a119c92d8d25b68950de4d0e6f337df18"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">string errorNumberToString </td>
          <td>(</td>
          <td class="paramtype">cl_int&#160;</td>
          <td class="paramname"><em>errorNumber</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert OpenCL error numbers to their string form. </p>
<p>Uses the error number definitions from cl.h. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">errorNumber</td><td>The error number returned from an OpenCL command. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>A name of the error. </dd></dl>

<p>Definition at line <a class="el" href="common_8cpp_source.html#l00368">368</a> of file <a class="el" href="common_8cpp_source.html">common.cpp</a>.</p>

</div>
</div>
<a class="anchor" id="af351b63fc0df43f3702d01de76d344ae"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">string imageChannelDataTypeToString </td>
          <td>(</td>
          <td class="paramtype">cl_channel_type&#160;</td>
          <td class="paramname"><em>channelDataType</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert cl_channel_type values into their string form. </p>
<p>Uses the channel data type definitions from cl.h. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">channelDataType</td><td>The channel data type value to convert. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The string form of the channel data type. </dd></dl>

<p>Definition at line <a class="el" href="common_8cpp_source.html#l00131">131</a> of file <a class="el" href="common_8cpp_source.html">common.cpp</a>.</p>

</div>
</div>
<a class="anchor" id="afbc9c225ddee8ca4913817d1d9f55307"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">string imageChannelOrderToString </td>
          <td>(</td>
          <td class="paramtype">cl_channel_order&#160;</td>
          <td class="paramname"><em>channelOrder</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Convert cl_channel_order values into their string form. </p>
<p>Uses the channel order definitions from cl.h. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">channelOrder</td><td>The channel order value to convert. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>The string form of the channel order. </dd></dl>

<p>Definition at line <a class="el" href="common_8cpp_source.html#l00096">96</a> of file <a class="el" href="common_8cpp_source.html">common.cpp</a>.</p>

</div>
</div>
<a class="anchor" id="ad800ae2b2358904a9051a31f76e711c3"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool isExtensionSupported </td>
          <td>(</td>
          <td class="paramtype">cl_device_id&#160;</td>
          <td class="paramname"><em>device</em>, </td>
        </tr>
        <tr>
          <td class="paramkey"></td>
          <td></td>
          <td class="paramtype">string&#160;</td>
          <td class="paramname"><em>extension</em>&#160;</td>
        </tr>
        <tr>
          <td></td>
          <td>)</td>
          <td></td><td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Definition at line <a class="el" href="common_8cpp_source.html#l00471">471</a> of file <a class="el" href="common_8cpp_source.html">common.cpp</a>.</p>

</div>
</div>
<a class="anchor" id="a33ff0013574626bb47147495e02b5d08"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool printProfilingInfo </td>
          <td>(</td>
          <td class="paramtype">cl_event&#160;</td>
          <td class="paramname"><em>event</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Print the profiling information associated with an OpenCL event. </p>
<p>Prints the time spent in the command queue, the time spent waiting before being submitted to a device, and the execution time. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">event</td><td>The event to get profiling information for. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>False if an error occurred, otherwise true. </dd></dl>

<p>Definition at line <a class="el" href="common_8cpp_source.html#l00018">18</a> of file <a class="el" href="common_8cpp_source.html">common.cpp</a>.</p>

</div>
</div>
<a class="anchor" id="a736045ae74d9ed8d35cacce59b92772a"></a>
<div class="memitem">
<div class="memproto">
      <table class="memname">
        <tr>
          <td class="memname">bool printSupported2DImageFormats </td>
          <td>(</td>
          <td class="paramtype">cl_context&#160;</td>
          <td class="paramname"><em>context</em></td><td>)</td>
          <td></td>
        </tr>
      </table>
</div><div class="memdoc">

<p>Print a list of the 2D OpenCL image formats supported. </p>
<dl class="params"><dt>Parameters</dt><dd>
  <table class="params">
    <tr><td class="paramdir">[in]</td><td class="paramname">context</td><td>The OpenCL context to use. </td></tr>
  </table>
  </dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd>False if an error occurred, otherwise true. </dd></dl>

<p>Definition at line <a class="el" href="common_8cpp_source.html#l00057">57</a> of file <a class="el" href="common_8cpp_source.html">common.cpp</a>.</p>

</div>
</div>
</div><!-- contents -->
</div><!-- doc-content -->
<!-- start footer part -->
<div id="nav-path" class="navpath"><!-- id is needed for treeview function! -->
  <ul>
    <li class="navelem"><a class="el" href="dir_bdd9a5d540de89e9fe90efdfc6973a4f.html">common</a></li><li class="navelem"><a class="el" href="common_8cpp.html">common.cpp</a></li>
    <li class="footer">
        <a href="http://www.arm.com/">(C) ARM Ltd. 2013</a>
    </li>
  </ul>
</div>
</body>
</html>
